//
//  MenuFirstViewController.m
//  土巴兔
//
//  Created by 千锋 on 16/1/7.
//  Copyright (c) 2016年 IOS1503薛凯. All rights reserved.
//

#import "MenuFirstViewController.h"
#import "Default.h"
@interface MenuFirstViewController ()<UIWebViewDelegate>
@property (strong,nonatomic)UIWebView* webview;
@end

@implementation MenuFirstViewController

- (void)viewDidLoad {
    [super viewDidLoad];
    self.tabBarController.tabBar.hidden=YES;
    // Do any additional setup after loading the view from its nib.
    [self createWebView];
}

- (void)createWebView{
    _webview=[[UIWebView alloc] initWithFrame:CGRectMake(0,60,DEVICEWIDTH , DEVICEHEIGHT-60)];
    [self.view addSubview:_webview];
    _webview.delegate=self;
    NSString* urlStr=@"http://mobileapi.to8to.com/index.php?module=freeCheck&action=introduce&no_button=0&requestType=3&version=2.5&ptag=3001225_5_1_4&to8to_from=%E9%AD%85%E6%97%8F%E5%BA%94%E7%94%A8%E4%B8%AD%E5%BF%83&channel=%E9%AD%85%E6%97%8F%E5%BA%94%E7%94%A8%E4%B8%AD%E5%BF%83&appversion=3.6.0&systemversion=22&to8to_token=5577450_75ff93ea5d8fae3c8a5a0ef1cb6dc1db&appostype=1&imei=569eb1056c38e1e8&uid=5577450";
    NSURL* url=[NSURL URLWithString:urlStr];
    NSURLRequest* request=[[NSURLRequest alloc] initWithURL:url];
    [_webview loadRequest:request];
}
- (IBAction)shareClick:(UIButton *)sender {
}
- (IBAction)backClick:(UIButton *)sender {
    //[self.navigationController popToRootViewControllerAnimated:NO];
    [self.navigationController popViewControllerAnimated:YES];
    self.tabBarController.tabBar.hidden=NO;
    //[self.navigationController dismissViewControllerAnimated:NO completion:nil];
//    [self.webview goBack];
}

@end
